package com.ews.onlineexchange.app.entity;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Set;

import javax.persistence.Transient;
import com.ews.onlineexchange.model.ServiceDepartment;

/**
 * 实体名称：资质类别 说明：资质类别，包含本类资质分级信息.
 * 
 * @author admin
 *
 */

public class TempQualificationClass implements Serializable {
	/**
	 * 
	 */
	private static final long	serialVersionUID	= 1L;
	private String id;
	private String name;
	private Set<TempSector> rootSectors = new LinkedHashSet<TempSector>();
	private Set<TempQualificationLevel>		levelOptions	= new LinkedHashSet<>();
	private String							auditDepartmentName;										// 资质审核部门
	private String							sectorNames;
	
	
	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Set<TempQualificationLevel> getLevelOptions() {
		return levelOptions;
	}
	

	public List<TempQualificationLevel> getLevelOptionList() {
		List<TempQualificationLevel> resultList = new ArrayList<TempQualificationLevel>();
		resultList.addAll(getLevelOptions());
		return resultList;
	}
	
//	@Transient
//	public List<TempQualificationLevel> getSortedLevelOptions() {
//		List<TempQualificationLevel> sortedLevelOptions = new ArrayList<>();
//		sortedLevelOptions.addAll(getLevelOptions());
//		Collections.sort(sortedLevelOptions, new QualificationLevelComparator());
//		return sortedLevelOptions;
//	}

	public void setLevelOptions(Set<TempQualificationLevel> levelOptions) {
		this.levelOptions = levelOptions;
	}

	public Set<TempSector> getRootSectors() {
		return rootSectors;
	}

	public void setRootSectors(Set<TempSector> rootSectors) {
		this.rootSectors = rootSectors;
	}

	
	
	public String getAuditDepartmentName() {
		return auditDepartmentName;
	}

	public void setAuditDepartmentName(String auditDepartmentName) {
		this.auditDepartmentName = auditDepartmentName;
	}

	public String getSectorNames() {
		return sectorNames;
	}

	public void setSectorNames(String sectorNames) {
		this.sectorNames = sectorNames;
	}

	
	
	
}
